CreateScalingGroup
Description
create a scaling group.
Request Method
POST
Request Path
/apsara/route/Ess/CreateScalingGroup
Request Parameters Common Parameters
Name | Location | Type | Required | Sample value | Description |
---|---|---|---|---|---|
VSwitchId | BODY | string | No | No sample value for this parameter. | If you create a VPC-type scaling group, you must specify the VSwitch ID. |
LoadBalancerIds | BODY | string | No | No sample value for this parameter. | load balancing instance ID list. A formatted Json Array:["lb-id0", "lb-id1",... "lb-idz"] supports up to 5 load balancing instances. |
VSwitchIds.N | BODY | string | No | No sample value for this parameter. | If the current parameter is used, the VSwitchId parameter will be ignored. multi-zone parameter, the value range of n is [1, 5], creating a scaling group can specify up to 5 different virtual switches under the same VPC. the priority of the virtual switch is sorted by number, and 1 is the first priority for creating an instance. when an instance cannot be created in the available area where the virtual switch with higher priority is located, the virtual switch with the next priority will be automatically selected to create the instance. |
MaxSize | BODY | integer | Yes | No sample value for this parameter. | The maximum number of ECS instances in the scaling group. Value range:[0, 100]. |
version | BODY | string | No | 2016-01-01 | version of api |
ScalingGroupName | BODY | string | No | No sample value for this parameter. | the display name of the scaling group, 2-40 English or Chinese characters, starting with numbers, large and small letters or Chinese, and can contain numbers, "_", "-" or ".". The same user account is unique in the same region. If this parameter is not specified, the default value is ScalingGroupId. |
MinSize | BODY | integer | Yes | No sample value for this parameter. | The minimum number of ECS instances in the scaling group. Value range:[0, 100]. |
DefaultCooldown | BODY | integer | No | No sample value for this parameter. | the default cooling time of the scaling group, value range:[0, 86400], unit: seconds. The default value is 300 seconds. |
regionId | BODY | string | Yes | No sample value for this parameter. | region id |
RemovalPolicy.N | BODY | string | No | No sample value for this parameter. | Policy for removing ECS instances from scaling groups. Optional value: OldestInstance: the earliest ECS instance added to the scaling group. NewestInstance: the latest ECS instance added to the scaling group. OldestScalingConfiguration: the instance created by the earliest scaling configuration. default values are: OldestScalingConfiguration, OldestInstance. You can enter up to 2. |
RegionId | BODY | string | Yes | No sample value for this parameter. | the region ID to which the scaling group belongs. |
DBInstanceIds | BODY | string | No | No sample value for this parameter. | RDS instance ID list. A formatted Json Array:["rm-id0", "rm-id1",... "rm-idz"], supports up to 8 RDS instances. |
Return data
Name | Type | Sample value | Description |
---|---|---|---|
RequestID | string | 1E3D5A1E0-67CA-43DA-24BC-EAF2D5A1E4DC | Request id |
Example
Successful Response example
{
"RequestID":"1E3D5A1E0-67CA-43DA-24BC-EAF2D5A1E4DC"
}
Failed Response example
{
"errorSample":
{
"resultCode":-1,
"resultMsg":"system error",
"result":null
}
}